package job;

import java.io.IOException;
import java.util.List;

import models.SystemParams;
import play.cache.Cache;
import play.jobs.Job;
import play.jobs.OnApplicationStart;
import services.SystemParamService;
import utils.BizConstants;
/**
 * 加载系统参数任务
 * @author wangshaoming
 *
 */
@OnApplicationStart
public class LoadParamJob extends Job {
	@Override
	public void doJob(){
		List<SystemParams> params=SystemParamService.getParams();
		for(SystemParams param : params){
			Cache.set(param.getParamid(), param.getParamvalue());
		}
	}
}
